<?php
/*! \brief
 * This is Simple Factory Framework class of Widget Framewok 2.0 /path/to/widget_old
 * And shot cut of widget pool relative object 
 * You can get all of the object of Widget Framework via this class
 *\author William Su
 */
require_once dirname(__FILE__).'/WFFrom.abstract.php';
class WFFrom16 extends AWFFrom
{
	/**
	 *\brief Description
	 * This method will return object of WFDataObject
	 * @return DataObject
	 */
    public function getDataObject(){
        if(!isset(self::$instance[__FUNCTION__])){
			require($this->getDocumentRoot().'/includes/config.php');
			//If config.php DBType="mysql"
			//DataObject will use below config to create MySQL connection string
			$wfconf_dbconfig["dbname"] = "tmwf_old"; //get database tmwf_old, for MySQL
			require($this->getDocumentRoot().'/includes/db/dataobject.php');
			self::$instance[__FUNCTION__] = new DataObject($wfconf_dbconfig);
		}
		$ret = self::$instance[__FUNCTION__];
		return $ret;
	}
}